-
Notifications
You must be signed in to change notification settings - Fork 10
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Integrate pyzag bindings for neml2 #178
Conversation
…but no more code changes should be required
Documentation preview removed. |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Changes on the c++ side look okay to me. A few minor comments.
Now onto the python part...
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
That's all my comments.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
We are running out of independent reviewers, so I'll just merge when all tests pass.
Urgh the clang-tidy check is unbearably slow. We need to fix it... |
Don't merge yet, I haven't rerun the stochastic example to make sure I got all the changing things. |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Let's not add nbdime, pyro, and tqdm as a global dependency, as they bring in a fair number of packages.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
My final comment:
I think torch.manual_seed doesn't guarantee reproducibility in different environments. The SVI example has two stochastic aspects: training and inference. If you save the checkpoint and reload it in the notebook, the trained model should be reproducible. But then IDK how to make the inference part (i.e., sampling the posterior) truly reproducible.
Actually I think the SVI examples in pyzag are fully-reproducible by setting the random seed in |
Setup an interface to evaluate and train NEML2 models in pyzag. This also makes pyzag a dependency of this package. Includes a few examples and tests. --------- Co-authored-by: Gary Hu <[email protected]>
Setup an interface to evaluate and train NEML2 models in pyzag. This also makes pyzag a dependency of this package. Includes a few examples and tests. --------- Co-authored-by: Gary Hu <[email protected]>
Add pyzag wrappers for NEML2 model and include some basic tests.
This will make pyzag a dependency of NEML2.